import Vue from 'vue'
import Router from 'vue-router'
import Login from "../components/account/Login";
import Register from "../components/account/Register";
import Home from "../components/Home";
import TypeRecord from "../components/Inventory_record/TypeRecord";
import NumRecord from "../components/Inventory_record/NumRecord";
import InventoryMenu from "../components/Inventory_record/InventoryMenu";
import Summary from "../components/summary/Summary";
import UploadTest from "../components/Inventory_record/UploadTest";
import HighchartTest from "../components/Inventory_record/HighchartTest";
Vue.use(Router)


export default new Router({
  routes: [
    {path: '/', redirect:'/login'},
    {path: '/login', component:Login},
    {path: '/register', component:Register},
    {path: '/home', component:Home,
      children:[
        {path: 'summary', component: Summary},
        {path:'inventory',component:InventoryMenu,
          children:[
            {path:'type',component:TypeRecord},
            {path: 'number',component: NumRecord},
            {path: 'upload',component: UploadTest},
            {path: 'hightchart',component: HighchartTest},
          ]
        },

      ]},

  ]
})
